﻿using System.Diagnostics.Contracts;

namespace System.Reactive
{
	public abstract class EventPatternSourceBase<TSender, TEventArgs>
#if SILVERLIGHT
 where TEventArgs : EventArgs
#endif
	{
		public EventPatternSourceBase(IObservable<EventPattern<TSender, TEventArgs>> source, Action<Action<TSender, TEventArgs>, EventPattern<TSender, TEventArgs>> invokeHandler)
		{
			Contract.Requires(source != null, null, "source != null");
			Contract.Requires(invokeHandler != null, null, "invokeHandler != null");
		}

		protected void Add(Delegate handler, Action<TSender, TEventArgs> invoke)
		{
			Contract.Requires(handler != null, null, "handler != null");
			Contract.Requires(invoke != null, null, "invoke != null");
		}

		protected void Remove(Delegate handler)
		{
			Contract.Requires(handler != null, null, "handler != null");
		}
	}
}